package com.wangjie.define.strategy.compare;

import java.util.Arrays;

public class Demo {
    public static void main(String[] args) {
        Cat[] cats = {new Cat(1,1),new Cat(5,5),new Cat(3,3)};
        Sorter<Cat> sorter = new Sorter<>();
        //sorter.sort(cats,new CatWeightComparator());
        sorter.sort(cats,new CatHeightComparator());
        System.out.println(Arrays.toString(cats));

    }
}
